package com.cnn.beans;

public class TestFactory {
    public static void main(String[] args) {
        Fruit f = BeanFactory.getInstance("com.cnn.beans.Apple");
        if (f!=null){
            f.eat();
        }

    }
}
